package com.allnas.springcloud.service;

import com.allnas.springcloud.entity.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;

/**
 * @author zhaojin
 */
@FeignClient(name = "producer-service")
public interface ProducerService {

    /**
     * query
     *
     * @param id
     * @return
     */
    @GetMapping("query/{id}")
    User query(@PathVariable Integer id);

    /**
     * check
     *
     * @param user
     * @return
     */
    @PostMapping("check")
    String check(User user);
}
